import { init as routerInit } from './base'
import system from './system'
import examples from './examples'
// import VueRouter from 'vue-router'
// import Vue from 'vue'

const routes = [
  ...system,
  ...examples
]

export default routerInit({
  routes, // 子路由
  mode: 'hash'
})

// const createRouter = () => new VueRouter({
//   // mode: 'history', // require service support
//   mode: 'hash',
//   scrollBehavior: () => ({ y: 0 }),
//   routes: routes
// })
// const router = createRouter()

// // Detail see: https://github.com/vuejs/vue-router/issues/1234#issuecomment-357941465
// export function resetRouter () {
//   const newRouter = createRouter()
//   router.matcher = newRouter.matcher // reset router
// }

// export default router
